From 59f3388f1c15f7327ba287e3471f06f888609b25 Mon Sep 17 00:00:00 2001 From: Ximin Luo Date: Thu, 14 Sep 2017 13:35:21 +0200 Subject: [PATCH] Work around #865549, fixes FTBFS on ppc64el --- debian/changelog | 6 ++++++ debian/rules | 9 ++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index d60f3bfff..4ad50a4bf 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +cargo (0.20.0-2) UNRELEASED; urgency=medium + + * Work around #865549, fixes FTBFS on ppc64el. + + -- Ximin Luo Thu, 14 Sep 2017 13:28:00 +0200 + cargo (0.20.0-1) unstable; urgency=medium * New upstream release. diff --git a/debian/rules b/debian/rules index 81ecff56d..f57328efd 100755 --- a/debian/rules +++ b/debian/rules @@ -24,8 +24,15 @@ CARGOFLAGS = --release --target=$(DEB_HOST_RUST_TYPE) --verbose # Cargo looks for config in and writes cache to $CARGO_HOME/ export CARGO_HOME = $(CURDIR)/debian/cargohome +# Work around #865549, needed when using older cargo that is affected by it. +# TODO: remove after cargo/unstable is a version that was compiled with rustc +# >= 1.18 where this bug was fixed in Debian (i.e. probably after 0.20). +ifeq (0,$(shell test $$(uname -s) = "Linux" -a $$(getconf PAGESIZE) -gt 4096; echo $$?)) + SYSTEM_WORKAROUNDS += ulimit -s $$(expr $$(getconf PAGESIZE) / 1024 '*' 256 + 8192); +endif + %: - dh $@ --with bash-completion + $(SYSTEM_WORKAROUNDS) dh $@ --with bash-completion override_dh_auto_configure: cp -a $(CURDIR)/Cargo.lock $(CURDIR)/.Cargo.lock.orig -- 2.30.2